<template>
<div class="contentmain">
    <el-form label-position="right" label-width="80px" :model="f">
        <el-form-item label="URL">
            <el-input type="text" v-model="f.url"></el-input>
        </el-form-item>
        <el-form-item label="URL">
            <el-button type="warning" @click="getData">查询</el-button>
        </el-form-item>
        <el-form-item label="paramsJSON">
            <el-input type="textarea" :rows="2" v-model="f.params"></el-input>
        </el-form-item>
        <el-form-item label="paramsJSON">
            <el-button type="warning" @click="getData2">查询</el-button>
        </el-form-item>
    </el-form>
</div>
</template>
<script>
import qs from 'qs'
export default {
    data(){
        return{
            f:{},
        }
    },
    methods:{
        getData(){
            axios.get(this.f.url).then(r=>{
            })
        },
        getData2(){
            var pp=JSON.parse(this.f.params)
            axios.post(this.f.url,pp,{headers: {'Content-Type': 'application/json;charset=utf-8'}}).then(r=>{
            })
        }
    }
}
</script>
